

//============= RECEIVE SERIAL COMMANDS =========================
// String to store ALPHANUMERIC DATA (i.e., integers, floating point numbers, unsigned ints, etc represented as DEC) sent wirelessly: 
char string[24]; // note: an integer is two bytes long, represented with a maximum of 5 digits, but we may send floats or unsigned int...
int indexString=0;

void processSerial() {
   // read the incoming byte:
  int val = Serial.read();
  
  // First, save only ASCII numeric characters (ASCII 0 - 9) on the string:
    if ((val >= '-') && (val <= '9')){ // this is 45 to 57 (included)
      string[indexString] = val;
      indexString++;
    }
    
    // COMMANDS:
    
    else if (val=='r') { // reset all spots
     spotConfig.allSpotsInit();   
    }
    
    
 }
 
 
